﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Entities;
using DataAccessLayer;

namespace BusinessLogicLayer
{
    public class GoiKhoaBLL
    {
        private GoiKhoaDAL dal;

        public GoiKhoaBLL()
        {
            try
            {
                dal = new GoiKhoaDAL();
            }
            catch { throw; }
        }

        public List<GoiKhoaEntity> getAll()
        {
            try
            {
                return dal.getAll();
            }
            catch { throw; }
        }

        public GoiKhoaEntity getById(int _id)
        {
            try
            {
                return dal.getById(_id);
            }
            catch { throw; }
        }

        public List<GoiKhoaEntity> getByLopHocId(int _id)
        {
            try
            {
                return dal.getByLopHocId(_id);
            }
            catch { throw; }
        }

        public int addGoiKhoa(GoiKhoaEntity _obj)
        {
            try
            {
                return dal.addGoiKhoa(_obj);
            }
            catch { throw; }
        }

        public int deleteGoiKhoa(int _id)
        {
            try
            {
                return dal.deleteGoiKhoa(_id);
            }
            catch { throw; }
        }

        public int updateGoiKhoa(GoiKhoaEntity _obj)
        {
            try
            {
                return dal.updateGoiKhoa(_obj);
            }
            catch { throw; }
        }
    }
}
